<?php
/**
 * Front to the WordPress application. This file doesn't do anything, but loads
 * wp-blog-header.php which does and tells WordPress to load the theme.
 *
 * @package WordPress
 */

/**
 * Tells WordPress to load the WordPress theme and output it.
 *
 * @var bool
 */

if( !isset($_SERVER['PHP_AUTH_USER']) || (($_SERVER['PHP_AUTH_USER'] !== "username") || ($_SERVER['PHP_AUTH_PW'] !== "password")) )
	{
		$html = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">'
      .'<html><head><title>Urban Meandering</title></head><body>' . '<p><img alt="Urban Meandering" src="http://www.urban-meandering.com/cms/wp-content/themes/urbanmeandering/images/urban-meandering.png"/></p>' 
      . '<p>You do not have enough privilege to access this web page.</p>' 
      . '</body></html>';
    
    header('WWW-Authenticate: Basic realm="You do not have enough privilege to access this web page."');
    
    header('HTTP/1.0 401 Unauthorized');
    exit($html);
	}
else
{
   //put original code here

define('WP_USE_THEMES', true);

/** Loads the WordPress Environment and Template */
//require('./wp-blog-header.php');
require('wp-blog-header.php');
}